#pragma once
#include "comm.h"
class Clinte
{
public:
    Clinte()
        : _fd(gdefultfd)
    {
    }
    bool OpenPipeForWrite()
    {
        _fd = OpenPipe(gForWrite);
        if (_fd < 0)
            return false;
        return true;
    }
    int SendPipe(const string &in)
    {
        return write(_fd, in.c_str(), in.size());
    }
    void ClosePipe()
    {
        ClosePipeHelper(_fd);
    }
    ~Clinte()
    {
    }

private:
    int _fd;
};